package com.huawei.appgallery.forum.section.card;

import android.content.Context;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import com.huawei.appgallery.forum.section.bean.Notice;
import o.bzf;
import o.cab.i;
import o.cab.j;
import o.cii;
import o.cil;
import o.cim.a;
import o.dof;
import o.ezn;
import o.fho;

public class BuoyForumNoticeCard extends ForumNoticeCard {
    public BuoyForumNoticeCard(Context context) {
        super(context);
    }

    protected int ˎ() {
        return i.ʼ;
    }

    public OnClickListener ˋ() {
        return new OnClickListener(this) {
            final /* synthetic */ BuoyForumNoticeCard ˎ;

            {
                this.ˎ = r1;
            }

            public void onClick(View view) {
                Object tag = view.getTag();
                if (tag instanceof Notice) {
                    Notice notice = (Notice) tag;
                    if (!dof.ॱ(notice.ॱॱ())) {
                        if (notice.ॱॱ().startsWith("buoy_forum|topic_detail|")) {
                            cil.ˋ(this.ˎ.ʼॱ, new a(notice).ˏ(String.valueOf(4)).ˋ());
                            this.ˎ.ˋ((Notice) tag);
                            return;
                        }
                        Context context = this.ˎ.ˊˋ.getContext();
                        if (context != null && !cii.ˊ().ˊ(context, notice)) {
                            ezn.ˊ().ॱ(context.getString(j.ॱ), 0);
                        }
                    }
                }
            }
        };
    }

    private void ˋ(Notice notice) {
        Bundle bundle = new Bundle();
        bundle.putString("SEGMENT_URI", notice.ॱॱ());
        bundle.putString("APPID", notice.ͺˏ());
        bundle.putInt("SOURCETYPE", 1);
        ((bzf) fho.ˏ().ˋ("Posts").ॱ(bzf.class)).ˎ(this.ʼॱ, bundle);
    }
}
